﻿using ShoppingEntity;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace IShoppingBll
{
    public interface IShoppingCartBll : IBaseBll<ShoppingCart>
    {
        /// <summary>
        /// 购物车页面分页展示、模糊查询
        /// </summary>
        /// <param name="page"></param>
        /// <param name="limit"></param>
        /// <param name="count"></param>
        /// <param name="commodityName"></param>
        /// <returns></returns>
        object GetShoppingCartPageList(int page, int limit, out int count, string commodityName, UserInfo userInfo);


        /// <summary>
        /// 获取购物车商品信息
        /// </summary>
        /// <param name="shoppingCartId"></param>
        /// <returns></returns>
        object GetShoppingCartOption(string shoppingCartId);


        /// <summary>
        /// 单件商品购买
        /// </summary>
        /// <param name="shoppingCartId"></param>
        bool PlayShoppingCart(string shoppingCartId, UserInfo userInfo, out string msg);


        /// <summary>
        /// 多件商品购买
        /// </summary>
        /// <param name="shoppingCartId"></param>
        /// <returns></returns>
        bool PlayAllShoppingCart(string[] shoppingCartId,UserInfo userInfo, out string msg);

    }
}
